Optimal. Leaf size=28 \[ \frac {\log (\cos (c+d x))}{a d}+\frac {\sec (c+d x)}{a d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.03, antiderivative size = 28, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 2, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.095, Rules used = {3964, 45}
\begin {gather*} \frac {\sec (c+d x)}{a d}+\frac {\log (\cos (c+d x))}{a d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 45
Rule 3964
Rubi steps
\begin {align*} \int \frac {\tan ^3(c+d x)}{a+a \sec (c+d x)} \, dx &=-\frac {\text {Subst}\left (\int \frac {a-a x}{x^2} \, dx,x,\cos (c+d x)\right )}{a^2 d}\\ &=-\frac {\text {Subst}\left (\int \left (\frac {a}{x^2}-\frac {a}{x}\right ) \, dx,x,\cos (c+d x)\right )}{a^2 d}\\ &=\frac {\log (\cos (c+d x))}{a d}+\frac {\sec (c+d x)}{a d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.07, size = 21, normalized size = 0.75 \begin {gather*} \frac {\log (\cos (c+d x))+\sec (c+d x)}{a d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.06, size = 25, normalized size = 0.89
method | result | size |
derivativedivides | \(-\frac {-\sec \left (d x +c \right )+\ln \left (\sec \left (d x +c \right )\right )}{d a}\) | \(25\) |
default | \(-\frac {-\sec \left (d x +c \right )+\ln \left (\sec \left (d x +c \right )\right )}{d a}\) | \(25\) |
risch | \(-\frac {i x}{a}-\frac {2 i c}{a d}+\frac {2 \,{\mathrm e}^{i \left (d x +c \right )}}{d a \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}+\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}{a d}\) | \(68\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.27, size = 28, normalized size = 1.00 \begin {gather*} \frac {\frac {\log \left (\cos \left (d x + c\right )\right )}{a} + \frac {1}{a \cos \left (d x + c\right )}}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.91, size = 33, normalized size = 1.18 \begin {gather*} \frac {\cos \left (d x + c\right ) \log \left (-\cos \left (d x + c\right )\right ) + 1}{a d \cos \left (d x + c\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {\tan ^{3}{\left (c + d x \right )}}{\sec {\left (c + d x \right )} + 1}\, dx}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 111 vs.
\(2 (28) = 56\).
time = 0.74, size = 111, normalized size = 3.96 \begin {gather*} -\frac {\frac {\log \left ({\left | -\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} + 1 \right |}\right )}{a} - \frac {\log \left ({\left | -\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} - 1 \right |}\right )}{a} + \frac {\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} - 1}{a {\left (\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} + 1\right )}}}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.22, size = 44, normalized size = 1.57 \begin {gather*} \frac {2}{d\,\left (a-a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\right )}-\frac {2\,\mathrm {atanh}\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\right )}{a\,d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________